package com.weeho.dongyong.dao;

import com.weeho.dongyong.entity.Approval;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public class ApprovalDao extends com.weeho.dongyong.dao.BaseDao {
    public int insertSelective(Approval record) {
        return sqlSession.insert("insertApprovalByPrimaryKey", record);
    }

    public int updateByPrimaryKeySelective(Approval record) {
        return sqlSession.update("updateApprovalByPrimaryKeySelective", record);
    }

    public int deleteByPrimaryKey(String id) {
        return sqlSession.update("deleteApprovalByPrimaryKey", id);
    }

    public Approval selectByPrimaryKey(String id) {
        return sqlSession.selectOne("selectApprovalByPrimaryKey", id);
    }

    public List<Approval> selectByCondition(Approval record) {
        return sqlSession.selectList("selectApprovalByCondition", record);
    }
}